import { Link } from '@brillout/docpress'
import { QuoteTeam } from '../../../components'
import { BlogHeader } from '../BlogHeader'

<BlogHeader authors={['brillout']} date={new Date('2025-04-29')} />

We are thrilled to unveil `globalContext`, available starting from `0.4.229`.
- <Link href="/globalContext" />
- <Link href="/getGlobalContext" />
- <Link href="/pageContext#globalContext">API > `pageContext.globalContext`</Link>
- <Link href="/onCreateGlobalContext" />
- <Link href="/onCreatePageContext" />

It's a foundational new primitive that unlocks new use cases and facilitates existing ones.

For example:
 - Global initial data can now <Link href="/data-fetching#global-data">simply be fetched in `+onCreateGlobalContext`</Link>.
 - Integrating a state management store with SSR is now <Link href="/store#manual-integration">an even more natural process</Link>.
 - You can use <Link href="/markdown#with-a-custom-setting-eager">`globalContext.pages` to access the metadata</Link> of all your pages.
 - You can <Link href="/auth#ssg">integrate authentication for SSG apps in a straightforward fashion</Link>.


It also unlocks features for Vike extensions. For example, it enables <Link href="/blog/vike-server">`vike-server`</Link> to automatically add the server middlewares of upcoming <Link href="/extensions">Vike extensions</Link> such as `vike-trpc`, `vike-telefunc`, and `vike-better-auth`.

We've updated Vike's documentation to feature `globalContext`, most notably:
 - <Link href="/data-fetching" />
 - <Link href="/store" />
 - <Link href="/auth" />
 - <Link href="/markdown#metadata" />



## Vision

The new `globalContext` primitive doubles down on Vike's philosophy of being an unopinionated core with low-level primitives, enabling unprecedented user freedom.

<div style={{marginBottom: 30, marginTop: 35}}>
<QuoteTeam>Vike empowers you to build whatever you want.</QuoteTeam>
</div>

We also care about zero-config, and that's why everything we released can also be used by Vike extensions.

> In general, we're working towards full feature parity between Vike extensions and the user land, enabling powerful <Link href="/extensions">Vike extensions</Link>.

> To foster user freedom, extensions are <Link href="/eject">ejectable</Link>.


## Roadmap

Thanks to `globalContext`, we will soon be able to merge and release our work on:
- [`vike-react-zustand`](https://github.com/vikejs/vike-react/pull/171) ([@nitedani](https://github.com/nitedani))
- [`vike-react-redux`](https://github.com/vikejs/vike-react/pull/161) ([@phonzammi](https://github.com/phonzammi))

We will then implement:
1. <Link href="/pricing">Open Source Pricing</Link>
1. Type-safe routing (see [`topic:routing`](https://github.com/vikejs/vike/issues?q=is%3Aissue%20state%3Aopen%20label%3Atopic%3Arouting))
1. Improved SSG support (see [`topic:ssg`](https://github.com/vikejs/vike/issues?q=is%3Aissue%20state%3Aopen%20label%3Atopic%3Assg))
1. A lot of polishing ✨
1. V1 release ⭐

In parallel to Vike's roadmap, we are:
 - Working on <Link href="/blog/vike-server#sharing-with-other-frameworks">making `vike-server` agnostic</Link> ([@magne4000](https://github.com/magne4000)) so that any Vite-based framework can use it.
 - Doing outreach to (better) explain Vike's vision.
